package com.mycar2w.cloud.entity;

import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
import java.sql.Timestamp;

/**
 * created time 2017/4/1
 *
 * @author ljc
 * @version V1.0
 */
@Entity
@Table(name = "car",schema ="mycar2wnew")
public class Car {
    private Long id;
    private String exteriorTrim;
    private String accidentInvestigation;
    private String images;
    private String testResult;
    private String yearlyInspection;
    private String compulsoryInsurance;
    private String commercialInsurance;
    private String transferCount;
    private String carMasterDescription;
    private Timestamp lastModifirdTime;
    private Timestamp ceateTime;
    private String trueMoney;
    private String saleMoney;
    private Long userId;
    private ApplieOrder appliedOrderId;
    private String isSale;

    @Basic
    @Column(name = "is_sale")
    public String getIsSale() {
        return isSale;
    }

    public void setIsSale(String isSale) {
        this.isSale = isSale;
    }

    @Id
    @Column(name = "id", nullable = false)
    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    @Basic
    @Column(name = "exterior_trim", nullable = true, length = 255)
    public String getExteriorTrim() {
        return exteriorTrim;
    }

    public void setExteriorTrim(String exteriorTrim) {
        this.exteriorTrim = exteriorTrim;
    }

    @Basic
    @Column(name = "accident_investigation", nullable = true, length = 255)
    public String getAccidentInvestigation() {
        return accidentInvestigation;
    }

    public void setAccidentInvestigation(String accidentInvestigation) {
        this.accidentInvestigation = accidentInvestigation;
    }

    @Basic
    @Column(name = "images", nullable = true, length = 255)
    public String getImages() {
        return images;
    }

    public void setImages(String images) {
        this.images = images;
    }

    @Basic
    @Column(name = "test_result", nullable = true, length = 255)
    public String getTestResult() {
        return testResult;
    }

    public void setTestResult(String testResult) {
        this.testResult = testResult;
    }

    @Basic
    @Column(name = "yearly_inspection", nullable = true, length = 255)
    public String getYearlyInspection() {
        return yearlyInspection;
    }

    public void setYearlyInspection(String yearlyInspection) {
        this.yearlyInspection = yearlyInspection;
    }

    @Basic
    @Column(name = "compulsory_insurance", nullable = true, length = 255)
    public String getCompulsoryInsurance() {
        return compulsoryInsurance;
    }

    public void setCompulsoryInsurance(String compulsoryInsurance) {
        this.compulsoryInsurance = compulsoryInsurance;
    }

    @Basic
    @Column(name = "commercial_insurance", nullable = true, length = 255)
    public String getCommercialInsurance() {
        return commercialInsurance;
    }

    public void setCommercialInsurance(String commercialInsurance) {
        this.commercialInsurance = commercialInsurance;
    }

    @Basic
    @Column(name = "transfer_count", nullable = true, length = 255)
    public String getTransferCount() {
        return transferCount;
    }

    public void setTransferCount(String transferCount) {
        this.transferCount = transferCount;
    }

    @Basic
    @Column(name = "car_master_description", nullable = true, length = 255)
    public String getCarMasterDescription() {
        return carMasterDescription;
    }

    public void setCarMasterDescription(String carMasterDescription) {
        this.carMasterDescription = carMasterDescription;
    }

    @Basic
    @Column(name = "last_modifird_time", nullable = true)
    public Timestamp getLastModifirdTime() {
        return lastModifirdTime;
    }

    public void setLastModifirdTime(Timestamp lastModifirdTime) {
        this.lastModifirdTime = lastModifirdTime;
    }

    @Basic
    @Column(name = "ceate_time", nullable = true)
    public Timestamp getCeateTime() {
        return ceateTime;
    }

    public void setCeateTime(Timestamp ceateTime) {
        this.ceateTime = ceateTime;
    }

    @Basic
    @Column(name = "true_money",nullable = true)
    public String getTrueMoney() {
        return trueMoney;
    }

    public void setTrueMoney(String trueMoney) {
        this.trueMoney = trueMoney;
    }

    @Basic
    @Column(name = "sale_money",nullable = true)
    public String getSaleMoney() {
        return saleMoney;
    }

    public void setSaleMoney(String saleMoney) {
        this.saleMoney = saleMoney;
    }

    @Basic
    @Column(name = "user_id", nullable = true)
    public Long getUserId() {
        return userId;
    }

    public void setUserId(Long userId) {
        this.userId = userId;
    }

    @ManyToOne
    @JoinColumn(name = "applied_order_id",referencedColumnName = "id")
    public ApplieOrder getAppliedOrderId() {
        return appliedOrderId;
    }

    public void setAppliedOrderId(ApplieOrder appliedOrderId) {
        this.appliedOrderId = appliedOrderId;
    }
}
